 *{
      padding: 0;
      margin: 0;
      list-style: none;
    }
    .tab{
      width:300px;
      height:300px;
      border: 1px solid red;
      margin: 100px auto;
    }
    .tab input{
      width: 100px;
      height: 30px;
      float: left;
    }
    .active{
      background: red;
      color:#FFF;
    }
    .tab li{
    width: 300px;
    height: 270px;
    background: pink;
    font-size: 100px;
    text-align: center;
    line-height: 270px;
    display: none;
    }
    .tab .show{
      display: block;
    }
    .tab section{
      overflow: hidden;
    }
    .tab2{
        width: 300px;
        height: 300px;
        position: relative;
        overflow: hidden;
        border: black;
        margin: 100px auto;
    }
    .tab2>ul{
        width: 900px;
        height: 300px;
        position: absolute;
        top:0;
        left: 0;
    }
    .tab2>ul:after{
        display: block;
        clear: both;
        content: '';
    }
    .tab2>ul>li{
        float: left;
        width: 300px;
        height: 300px;
        background: pink;
        text-align: center;
        font-size: 50px;
        line-height: 300px;
    }
    .btn1{
        position:absolute ;
        left: 0;
        top:45%;
    }
    .btn2{
        position:absolute ;
        right: 0;
        top:45%;
    }